home *** CD-ROM | disk | FTP | other *** search
/ Aminet 4 / Aminet 4 - November 1994.iso / aminet / comm / cnet / cn3demo2.lha / programming / cnet.h < prev    next >
C/C++ Source or Header  |  1994-01-03  |  52KB  |  2,315 lines

  1. #include <exec/types.h>
  2.  
  3. #define CNET_VERSION "$VER: CNet PRO 3.03"
  4.  
  5. #define TOP_STAT 51
  6. #define TOP_NOSTAT 11
  7.  
  8. #define C_BLACK  0
  9. #define C_RED    4
  10. #define C_GREEN  2
  11. #define C_YELLOW 6
  12. #define C_BLUE   1
  13. #define C_PURPLE 5
  14. #define C_CYAN   3
  15. #define C_WHITE  7
  16.  
  17. #define GRN_BLK 0x20
  18. #define YEL_BLK 0x60
  19. #define BLU_BLU 0x11
  20. #define CYN_BLK 0x30
  21. #define CYN_BLU 0x31
  22. #define WHT_BLK 0x70
  23. #define WHT_RED 0x74
  24. #define WHT_BLU 0x71
  25. #define WHT_PUR 0x75
  26.  
  27. #define EVER ;;
  28.  
  29. #define EDHANDLE_FLAG        0x01
  30. #define EDREALNAME_FLAG        0x02
  31. #define EDADDRESS_FLAG        0x04
  32. #define EDVOICE_FLAG        0x08
  33. #define EDDATA_FLAG        0x10
  34. #define BANNER_FLAG        0x20
  35. #define NOT_USED_FLAG        0x40
  36. #define PORTMONITOR_FLAG    0x80
  37. #define VOTEMAINT_FLAG        0x0100
  38. #define ALARMSYSOP_FLAG        0x0200
  39. #define OPENSCREEN_FLAG        0x0400
  40. #define OPENCAPTURE_FLAG    0x0800
  41. #define NETMAIL_FLAG        0x1000
  42. #define FREQSEND_FLAG        0x2000
  43. #define NETCOSTEXEMPT_FLAG    0x4000
  44. #define EXPANSION1_FLAG        0x8000
  45. #define EXPANSION2_FLAG        0x010000
  46. #define EXPANSION3_FLAG        0x020000
  47. #define EXPANSION4_FLAG        0x040000
  48. #define UUCPMAIL_FLAG        0x080000
  49. #define NETCOSTCREDITS_FLAG    0x100000
  50. #define HOLDANDCRASH_FLAG    0x200000
  51. #define EXPANSION8_FLAG        0x400000
  52. #define EXPANSION9_FLAG        0x800000
  53. #define EXPANSION10_FLAG    0x01000000
  54.  
  55. #define EMAIL_FLAG        0x01    /* bit defs for ABits of struct Privs */
  56. #define    PFILE_FLAG        0x02
  57. #define GFILE_FLAG        0x04
  58. #define    ULIST_FLAG        0x08
  59. #define    SYSOP_FLAG        0x10
  60. #define    REWARDS_FLAG        0x20    /* may receive download rewards? */
  61. #define    FCREDEX_FLAG        0x40
  62. #define BCREDEX_FLAG        0x80
  63. #define    EXPIREMAIL_FLAG        0x0100
  64. #define    BULK_FLAG        0x0200
  65. #define PARTY_FLAG        0x0400
  66. #define    URGENT_FLAG        0x0800
  67. #define    TIMESBP_FLAG        0x1000
  68. #define    FILEADD_FLAG        0x2000
  69. #define    READANY_FLAG        0x4000
  70. #define    DELETEANY_FLAG        0x8000
  71. #define XXXXXXXXX_FLAG        0x010000    /* not used */
  72. #define    XXXXXXXXX4_FLAG        0x020000
  73. #define AUTOVALID_FLAG        0x040000
  74. #define    XXXXXXXXX2_FLAG        0x080000    /* not used */
  75. #define    SEEANON_FLAG        0x100000
  76. #define    XXXXXXXXX3_FLAG        0x200000    /* not used */
  77. #define    CONF_FLAG        0x400000
  78. #define CONFCON_FLAG        0x800000
  79. #define MCI1_FLAG        0x01000000
  80. #define MCI2_FLAG        0x02000000
  81. #define    RELOGON_FLAG        0x04000000
  82. #define RECEIVEMAIL_FLAG     0x08000000
  83. #define FORWARD_FLAG           0x10000000
  84. #define VOTETOPIC_FLAG      0x20000000
  85. #define VOTECHOICE_FLAG     0x40000000
  86. #define NOLOCKS_FLAG        0x80000000
  87.  
  88. struct RangeContext {
  89.     long    nparts;
  90.     long    parts[10][2];
  91.     long    set;
  92.     long    element;
  93. };
  94.  
  95. struct DrawElement {
  96.     UBYTE    x;        /* x screen position */
  97.     UBYTE    y;        /* y screen position */
  98.     UBYTE    att;        /* the character's attribute (colors) */
  99.     UBYTE    att2;        /* the character's attribute (others) */
  100.     UBYTE    c;        /* the character */
  101.     UBYTE    att0;        /* Was the attribute (underneath) */
  102.     UBYTE    att20;        /* Was the attribute (underneath) */
  103.     UBYTE    c0;        /* Was the character (underneath) */
  104. };
  105.  
  106. struct VDEentry {
  107.     char    text[48];
  108.  
  109.     short    xpos,        /* where to print these things */
  110.         ypos;
  111.  
  112.     long    min,        /* for numerix */
  113.         max;        /* for numerix */
  114.  
  115.     short    length,        /* for string entry, field size */
  116.                 /* for bit boolean, which bit? */
  117.  
  118.         type;        /* 0 = UBYTE 0/1
  119.                    1 = ULONG BIT 0/1
  120.                    2 = Text (char *)
  121.                    3 = BYTE numeric
  122.                    4 = short numeric
  123.                    5 = USHORT numeric
  124.                    6 = long numeric
  125.                    7 = date
  126.                    8 = flags
  127.                    9 = ordered BBSTEXT list
  128.                    10= ordered BBSMENU list
  129.                    11= char **
  130.                    12= UBYTE BIT 0/1 */
  131.  
  132.     long    offset;        /* position in structure */
  133.  
  134.     short    screen0,    /* belongs-to screen */
  135.         screen2;    /* goes-to screen, -1 for exit */
  136.  
  137.     short    goup,        /* VDEentry for movement */
  138.         godown,
  139.         goleft,
  140.         goright;
  141.  
  142.     UWORD    ghost;
  143. };
  144.  
  145. struct TermLink {
  146.     char    dial[32];
  147.     long    baud;
  148.     char    ports[40];
  149.     long    access;
  150.     short    rate;
  151.     char    name[38];
  152.     short    databits;
  153. };
  154.  
  155. struct LogType {
  156.     char    name  [10];
  157.     short    id;
  158.  
  159.     char    custom[10];
  160.  
  161.     UBYTE    flag;
  162.     UBYTE    other;
  163. };
  164.  
  165. struct    FidoType {
  166.     char    Name[25];
  167.  
  168.     USHORT    ZoneB,  Zone,
  169.         NetB,   Net,
  170.         NodeB,  Node,
  171.         PointB, Point;
  172.  
  173.     USHORT    ZoneC, NetC, NodeC, PointC;
  174.  
  175.     char    EchoOrigin[78];
  176.     USHORT    LoZone;
  177.  
  178.     char    NetOrigin[76];
  179.     USHORT    Pointnet;
  180.     USHORT    HiZone;
  181. };
  182.  
  183. struct    ProtoType {
  184.     char    Name[16];
  185.     char    Env[36];
  186.     short    Flags;
  187.     char    One[2];
  188.     char    Path[22];
  189. };
  190.  
  191. struct    ArcType {
  192.     char    Suffix[8];
  193.     char    Keyword[16];
  194.     char    View[64];
  195.     char    Test[64];
  196.     char    Pack[64];
  197.     char    Extract[64];
  198.  
  199.     long    Row;
  200.     long    Column;
  201. };
  202.  
  203. struct    EditorType {
  204.     char    name[20];
  205.     char    path[32];
  206.     long    flags;
  207. };
  208.  
  209. struct    Config1 {
  210.     char    MySystemName[26];
  211.     char    MySysopName[26];
  212.     char    MyLocation[26];
  213.     char    MyPhoneNumber[20];
  214.     char    MyBBSID[10];
  215.  
  216.     char    FontName[40];
  217.     long    DefBalance;
  218.     long    DefaultColor;
  219.     long    BlankTicks;
  220.     long    BlankBright;
  221.  
  222.     long    nUDBASEx;        /* highest UDBASE partition */
  223.     long    MaxShortLines;        /* Short description lines */
  224.     long    MaxOpenPfiles;        /* stuff from BBSCONFIG */
  225.     long    maxUserAccounts;
  226.     long    NumRooms;
  227.     long    nLinkPorts;        /* max link ID            */
  228.     long    nsub;            /* */
  229.     long    BListPurgeDays;
  230.     long    nselect;        /* */
  231.     long    nupload;
  232.     long    nlist;
  233.     long    maxYankTasks;
  234.     long    maxYankSize;
  235.     long    maxYankDays;
  236.     long    maxLogonAttempts;
  237.     long    maxLogonTime;
  238.     long    maxYanksPerUser;
  239.  
  240.     long    DefNetCredits;
  241.     long    DefByteCredits;
  242.     long    DefFileCredits;
  243.     char    MyCountry[4];
  244.     char    MyAreaCode[12];
  245.     char    DefDefProtocol[4];
  246.     char    Yprefix[4];        /* Yank identifier */
  247.     long    DefDoorPoints;
  248.     long    DefTimeForm;
  249.  
  250.     UBYTE    MyLinkID;
  251.  
  252.     UBYTE    LogonFeedback;
  253.     UBYTE    LogonSearch;
  254.     UBYTE    GuestUsers;
  255.     UBYTE    HideStatus;
  256.     UBYTE    ConfProfile;
  257.     UBYTE    MailFeedback;
  258.     UBYTE    SeparateTexts;
  259.     UBYTE    IndentSpaces;
  260.     UBYTE    CIDvalidate;
  261.     UBYTE    CIDhandleskip;
  262.     UBYTE    SkipIdlePorts;
  263.  
  264.     char    MyLinkPass[8];
  265.  
  266.     char    OLMpath[40],
  267.         ZIPpath[40],
  268.         EXTRACTpath[40],
  269.         YANKwork[40],
  270.         RAMpath[40],
  271.         TERMpath[40],
  272.         LocalEditor[40],
  273.         CDROMpath[40],
  274.         DictPath[40];
  275.  
  276.     char    FKey [10][80];
  277.     char    TFKey[10][80];
  278.  
  279.     USHORT    DColors2[2];
  280.     USHORT    DColors4[4];
  281.     USHORT    DColors8[8];
  282.     USHORT    DColors16[16];
  283.  
  284.     long    narc;
  285.     long    ned;
  286.     long    nproto;
  287.     long    nfido;
  288.     long    nlog;
  289.  
  290.     struct    ArcType       arc   [20];
  291.     struct    EditorType ed     [8];
  292.     struct    ProtoType  proto [16];
  293.     struct    FidoType   fido  [12];
  294.     struct    LogType       log   [88];
  295.  
  296.     char    MyUUCPName[44];
  297.     char    OutboundPath[40];
  298.     char    InboundPath[40];
  299.  
  300.     ULONG    TossInputSize;
  301.     ULONG    TossOutputSize;
  302.     USHORT    DupeTableSize;
  303.  
  304.     UBYTE    BadUnknown;
  305.     UBYTE    Trapdoor174;
  306.     UBYTE    BadDupes;
  307.     UBYTE    ZoneGateAdjust;
  308.     UBYTE    ShowKludges;
  309.     UBYTE    ThreeD;
  310.     UBYTE    DeleteUUCP;
  311.     UBYTE    CIDsilence;
  312.     UBYTE    TwoDotMsg;
  313.  
  314.     char    expansion[73];
  315.  
  316.     char    Nodelist[40];
  317. };
  318.  
  319. struct LinkPortUser {
  320.     short    tick;
  321.  
  322.     UBYTE    channel;
  323.     char    name[21];
  324. };
  325.  
  326. struct LinkPort {
  327.     long    s;                /* serial number */
  328.  
  329.     short    ports;
  330.     char    name[22];
  331.  
  332.     struct    LinkPortUser user[100];
  333. };
  334.  
  335. struct IsDate {        /* must LEAVE as BYTE */
  336.     BYTE Year;
  337.     BYTE Month;
  338.     BYTE Date;
  339.     BYTE Hour;
  340.     BYTE Minute;
  341.     BYTE Second;
  342. };
  343.  
  344. /* LONG aligned */
  345.  
  346. struct RoomConfig {
  347.     long    Access;        /* which groups may enter */
  348.  
  349.     short    Creator;    /* who created this room (id#) */
  350.     short    Youngest;
  351.     short    Oldest;
  352.  
  353.     UBYTE    Doors;
  354.     UBYTE    NameType;
  355.     UBYTE    Gender;
  356.     UBYTE    Quiet;
  357.     UBYTE    Public;
  358.     UBYTE    PermaRoom;
  359.  
  360.     char    Name[31];
  361.     char    Topic[31];
  362.     char    Entry[81];    /* Messages for entry, exit */
  363.     char    Exit[81];
  364.  
  365.     UBYTE    Scribe;            /* are we writing a scribe? */
  366.     UBYTE    MCIScribe;        /* remove MCI's ?? */
  367.     char    SName[78];        /* name of current scribe file */
  368.  
  369.     UBYTE    Channel;
  370.     UBYTE    LinkID;
  371.  
  372.     UBYTE    Invited[300];        /* 1 bit each for 2400 users */
  373.  
  374.     short    MaxUsers;
  375.     UBYTE    Chaos;
  376.     UBYTE    LurkTimeout;
  377.  
  378.     short    NoiseSet;
  379. };
  380.  
  381. struct Room {
  382.     struct    RoomConfig rc;
  383.  
  384.     long    Pointer;
  385.     long    Users;            /* how many users are in this room */
  386.  
  387.     short    pSBuff;            /* pointer into Scribe Buffer */
  388.  
  389.     UBYTE    Buffer[15000];        /* Actual I/O buffer (Q) */
  390.  
  391.     UBYTE    SBuff[1024];        /* buffer for Scribe */
  392. };
  393.  
  394. /* LONG aligned.  Total length == 304 */
  395.  
  396. struct RoomUser {
  397.     long    MyPointer;        /* 0 */
  398.     long    UID;            /* 4 */
  399.     short    Room;            /* 8 */
  400.  
  401.     char    Entry[71];        /* 10 */
  402.     char    Exit[71];
  403.     char    Topic[31];
  404.     char    Alias[21];
  405.     char    Noise[71];
  406.     UBYTE    Action;
  407.     UBYTE    DefRoom;
  408.     UBYTE    Quit;
  409.     UBYTE    AllowReal;
  410.  
  411.     UBYTE    expansion[25];        /* 278 */
  412. };
  413.  
  414. struct SelectType {            /* Select list */
  415.     long    Size;
  416.  
  417.     char    Title   [32];
  418.     char    Location[96];        /* physical path to file */
  419.     short    Base;            /* physical subboard # */
  420.  
  421.     UBYTE    SDownFiles;        /* Which accounting schedule ? */
  422.     UBYTE    SDownBytes;
  423.  
  424.     UBYTE    temp_rem;        /* DS from DS list!! */
  425.     UBYTE    CDROM;            /* Copy to CDROMpath before download? */
  426.     BYTE    FreeStuff;
  427.     UBYTE    AutoKill;        /* 1==mark for amaint deletion when downloaded
  428.                        2==Yank, 3==DELETE when unselected */
  429.  
  430.     long    ByteDownload;        /* credits to subtract when this */
  431.     short    FileDownload;        /* item is downloaded ... */
  432.                     /* makes * faster by being here */
  433.     struct    IsDate ADate;        /* utility ... AO adopt dates? */
  434.  
  435.     long    Number;            /* item number */
  436. };
  437.  
  438. struct BaseUser {
  439.     long    UID;            /* ==IDNumber if user's been here */
  440.  
  441.     BYTE    Joined;            /* -1 dropped, 0 sub.def., 1 joined  */
  442.     BYTE    Invited;        /* -1 denied,  0 sub.def., 1 invited */
  443.     BYTE    Sort;
  444.     UBYTE    scan_flags;        /* used to 'mark' subboards */
  445.  
  446.     struct    IsDate LastMNew;
  447.     struct    IsDate MNewDate;
  448.  
  449.     long    Created;        /* when sub was created */
  450.  
  451.     char    Alias[22];
  452.     BYTE    Carbons;        /* -1 no, 0 sub.def., 1 yes */
  453.     UBYTE    MNewSave;
  454.  
  455.     short    tome0;
  456.     short    tome1;            /* while "online" */
  457.  
  458.     char    expansion[12];
  459. };
  460.  
  461. struct HeaderType {
  462.     struct    IsDate ShowDate;    /* for display */
  463.     struct    IsDate EditDate;    /* last edited */
  464.     struct    IsDate PostDate;
  465.  
  466.     short    ByAccount;
  467.  
  468.     char    NetAddress[52];        /* May be shortened */
  469.     long    UUCPnumber;
  470.  
  471.     char    other[16];
  472.  
  473.     char    By[36];            /* Real name or alias */
  474.     char    ByUser[24];        /* Handle */
  475.     long    ByID;
  476.  
  477.     char    To[36];
  478.     char    ToUser[24];
  479.     long    ToID;
  480.  
  481.     UBYTE    ByNotParanoid;        /* allow showing real name? */
  482.     UBYTE    ByAnonymous;
  483.     UBYTE    ToAnonymous;
  484.     UBYTE    Private;
  485.  
  486.     UBYTE    Imported;
  487.     UBYTE    ByAlias;        /* is BY an alais for ByUser? */
  488.     UBYTE    ToNotParanoid;        /* allow showing real name? */
  489.     UBYTE    ToAlias;        /* is TO an alias for ToUser? */
  490.  
  491.     short    ToAccount;        /* for SendToMailBox() */
  492.  
  493.     ULONG    Magic;            /* to ensure alignment   */
  494.     long    Number;            /* unique message number */
  495.  
  496.     long    Text;
  497.     long    TextLen;
  498.  
  499.     char    Organ[31];
  500.  
  501.     UBYTE    Received;
  502.  
  503.     short    unknown;
  504.  
  505.     long    Next;
  506.     long    Previous;
  507. };
  508.  
  509. struct    OldMessageType {
  510.     long    ItemNumber;
  511.     long    ResponseNumber;
  512.     long    ByID;
  513.     long    ToID;
  514.  
  515.     struct    IsDate PostDate;
  516.  
  517.     UBYTE    Imported;
  518.     UBYTE    IsFile;
  519. };
  520.  
  521. struct    MessageType3 {
  522.     long    ItemNumber;        /* item serial ID# */
  523.     long    Seek;            /* position in text */
  524.     long    ByID;
  525.     long    ToID;
  526.     long    Number;            /* serial ID# */
  527.  
  528.     struct    IsDate PostDate;
  529.  
  530.     UBYTE    Imported;
  531.     UBYTE    IsFile;
  532. };
  533.  
  534. struct    OldItemType {
  535.     long    Number;
  536.     long    Response1;        /*  1st valid response # */
  537.     long    Responses;        /* last valid response # */
  538.  
  539.     char    Title[72];
  540.     struct    IsDate PostDate;    /* new item ?      */
  541.     struct    IsDate RespDate;    /* new responses ? */
  542.  
  543.     long    ByID;
  544.     long    ToID;
  545.  
  546.     long    Size;
  547.     long    Downloads;
  548.     char    Info[84];
  549.     struct    IsDate UsedDate;    /* new downloads ? */
  550.     short    Part;            /* which partition? */
  551.  
  552.     short    fcredit;    /* Remember the Accounting credits */
  553.     short    bcredit;    /* and File/Byte credits given for */
  554.     UBYTE    fratio;        /* for this item so they can accurately */
  555.     UBYTE    bratio;        /* be removed if un-validated or killed */
  556.  
  557.     UBYTE    Private;
  558.     UBYTE    Killed;
  559.  
  560.     UBYTE    PleaseKill;
  561.     UBYTE    Frozen;
  562.     UBYTE    Free;
  563.     UBYTE    Protected;
  564.  
  565.     UBYTE    Favorite;
  566.     UBYTE    Validated;
  567.     UBYTE    Finished;
  568.     UBYTE    Described;
  569.  
  570.     UBYTE    Transformed;        /* has the script been ran? */
  571.     UBYTE    MissingPost;
  572.     UBYTE    MissingFile;
  573.     BYTE    Integrity;        /* 0 == not tested
  574.                        1 == passed
  575.                       -1 == failed
  576.                        2 == not testable */
  577.  
  578.     short    ByAccount;        /* for AddCredits */
  579.  
  580.     short    order;            /* for New Files Scan */
  581.     short    base;
  582.     UBYTE    WasMoved;
  583.  
  584.     BYTE    expand[57];
  585. };
  586.  
  587. /* size = 34 */
  588.  
  589. struct    ItemHeader {
  590.     long    Number;
  591.     long    Size;            /* ==0-->POST, not file */
  592.     long    Responses;        /* How many responses */
  593.  
  594.     struct    IsDate PostDate;    /* new item ?      */
  595.     struct    IsDate RespDate;    /* new responses ? */
  596.  
  597.     UBYTE    TitleSort[9];
  598.     UBYTE    Killed;
  599. };
  600.  
  601. struct    ItemType3 {
  602.     char    Title[42];        /* 0 */
  603.     short    ByAccount;        /* 42 Uploader's account # */
  604.  
  605.     long    ByID;            /* 44 */
  606.     long    ToID;            /* 48 */
  607.  
  608.     struct    IsDate UsedDate;    /* 52 new downloads ? */
  609.     short    Part;            /* 58 which partition? */
  610.  
  611.     long    Downloads;        /* 60 */
  612.  
  613.     long    ByteCharges;        /* 64 Accounting system charges to the */
  614.     short    FileCharges;        /* 68 uploader ... */
  615.  
  616.     UBYTE    Private;        /* 70 */
  617.     UBYTE    DLnotifyULer;        /* 71 */
  618.  
  619.     UBYTE    PleaseKill_NOT;        /* 72 */
  620.     UBYTE    Frozen;            /* 73 */
  621.     UBYTE    Free;            /* 74 */
  622.     UBYTE    delta;
  623.  
  624.     UBYTE    Favorite;        /* 76 */
  625.     UBYTE    Validated;        /* 77 */
  626.     UBYTE    Finished;        /* 78 */
  627.     UBYTE    Described;        /* 79 */
  628.  
  629.     UBYTE    Transformed;        /* 80 has the script been ran? */
  630.     UBYTE    PurgeKill;        /* 81 delete file when purged? */
  631.     UBYTE    MissingFile;        /* 82 offline? */
  632.     BYTE    Integrity;        /* 83    0 == not tested
  633.                         1 == passed
  634.                            -1 == failed
  635.                         2 == not testable */
  636.  
  637.     UBYTE    AutoGrab;        /* 84 ASCII-Grab when read */
  638.     UBYTE    PurgeStatus;        /* 85   0 == Auto
  639.                         1 == @DL
  640.                         2 == Query@DL
  641.                         3 == @Amaint
  642.                         4 == Protected */
  643.  
  644.     struct    IsDate ShowDate;
  645.  
  646.     UBYTE    nada[7];        /*  86 reserved */
  647.     UBYTE    VirusChecked;        /*  99 */
  648.     UBYTE    override;        /* 100 */
  649.     UBYTE    loaded;            /* 101 is in memory? */
  650.  
  651.     short    FilePayBack;        /* 102 after each download */
  652.     long    BytePayBack;        /* 104 Credits to award the uploader */
  653.  
  654.     long    VoteLink;        /* 108 vote serial# */
  655.     long    SizeTemp;        /* 112 used privately by AT */
  656.  
  657.     long    ByteRewards;        /* 116 # of bytes awarded so far */
  658.     long    FileRewards;        /* 120 # of files awarded so far */
  659.  
  660.     long    ByteDownload;        /* 124 Number of byte cred to download */
  661.     short    FileDownload;        /* 128 Number of file cred to download */
  662.  
  663.     struct    IsDate DLableFrom;    /* 130 */
  664.     struct    IsDate DLableTo;    /* 136 */
  665.     struct    IsDate PurgeOn;        /* 142 */
  666.  
  667.     long    BestCPS;        /* 148 best download rate this file */
  668.  
  669.     long    First;            /* 152 pointer to post in _Text */
  670.     long    Last;            /* 156 pointer to last response in _Text */
  671.  
  672.     long    InfoX;            /* 160 pointer into _Short */
  673.     long    InfoLen;        /* 164 */
  674. };
  675.  
  676. struct FreeType
  677. {
  678.     long    start;
  679.     long    length;
  680.     struct    FreeType *next;
  681. };
  682.  
  683. /* Total length == 332 */
  684.  
  685. struct OldSubboardType {
  686.     char    Title[31];        /* 0  */
  687.     char    SubDirName[21];        /* 31 */
  688.     char    Part0Path [40];        /* 52 */
  689.     long    Parts;            /* 92 partitions 0-31 now allowed */
  690.  
  691.     long    SubOpIDs [6];        /* 96 */
  692.  
  693.     short    MRewardBytes;        /* 120 % of byte  size to award */
  694.     short    NRewardFiles;        /* 122 # of file creds to award
  695.                            uploader each time his file is
  696.                            downloaded */
  697.  
  698.     struct    FreeType *free;        /* 124 */
  699.     long    nf;            /* 128 */
  700.     long    nfmax;            /* 132 */
  701.  
  702.     short    SubOpAccs[6];        /* 136 */
  703.  
  704.     char    Filler[4];        /* 148 shown during SCAN */
  705.  
  706.     short    fdelta;            /* 152 */
  707.     short    fowner;            /* 154 current owner of "free" */
  708.  
  709.     UBYTE    Direct;            /* 156 Disk-exchange type */
  710.     UBYTE    Vote;            /* 157 May non-sysops add topics? */
  711.  
  712.     short    FreeDays;        /* 158 when files are auto-free */
  713.  
  714.     UBYTE    Subdirectory;
  715.     UBYTE    Closed;
  716.  
  717.     long    UnionFlags;        /* 162 Must have all of these flags */
  718.     long    Access;            /* 166 Groups which may ENTER */
  719.     long    PostAccess;        /* 170 Groups which may Post  */
  720.     long    RespondAccess;        /* 174 ... Respond */
  721.     long    UploadAccess;        /* 178 ... Upload */
  722.     long    DownloadAccess;        /* 182 ... Download */
  723.     long    ComputerTypes;        /* 186 */
  724.     long    Hours;            /* 190 restricted entry hours */
  725.     long    HourUnionFlags;        /* 194 */
  726.     long    HourAccess;        /* 198 groups which may Enter during Hours*/
  727.     long    Baud;            /* 202 minimum Baud rate to enter */
  728.     long    BaudHours;        /* 206 hours to enforce min baud rate */
  729.  
  730.     UBYTE    Gender;            /* 210 0 or 'M', 'F' */
  731.     UBYTE    AllowAliases;
  732.     UBYTE    OnlyOnce;        /* 212 */
  733.     UBYTE    Youngest;        /* 213 */
  734.  
  735.     UBYTE    EXTRA;
  736.  
  737.     UBYTE    Oldest;            /* 215 */
  738.  
  739.     struct    IsDate    Sent;        /* 216 FIDO to track new messages */
  740.  
  741.     short    MDownBytes;        /* 222 % of download bytes to subtract */
  742.     short    NDownFiles;        /* 224 # of files to subtract per download */
  743.     short    MTimeCredit;        /* 226 % of time to give back for uploads */
  744.  
  745.     long    MinFreeBytes;    /* 228 to upload in this subboard */
  746.     short    SubSort;    /* 232 */
  747.     short    InactiveDays;    /* 234 */
  748.  
  749.     UBYTE    RealNames;    /* 236 use real names instead of Handles? */
  750.     UBYTE    Addressees;
  751.     UBYTE    Anonymous;
  752.     UBYTE    override;    /* 239 how to set the use defaults flags in
  753.                     newly uploaded items */
  754.  
  755.     UBYTE    Verification;    /* 240 */
  756.     UBYTE    DupCheck;
  757.     UBYTE    ShowUnvalidated;
  758.     UBYTE    NoMCI;
  759.  
  760.     UBYTE    PrivateArea;    /* 244 0/1 No/Yes ... 2==FORCE */
  761.     BYTE    SDownFiles;    /* Which download charge schedules? */
  762.     BYTE    SDownBytes;
  763.     UBYTE    TestImmediate;    /* test at upload time */
  764.  
  765.     UBYTE    TransImmediate;    /* 248 run script at upload time */
  766.     UBYTE    AutoAdopt;    /* Adopt Orphans at a-maint */
  767.     UBYTE    WeedResponses;    /* Use inactive days against indiv responses */
  768.     UBYTE    NoSignatures;
  769.  
  770.     UBYTE    NoReadCharges;    /* 252 opt to short circuit accounting system */
  771.     UBYTE    NoWriteCharges; /* 253 for reading/writing messages */
  772.  
  773.     long    Arcs;        /* 254 which Arcs in BBSARC are allowed uploaded*/
  774.  
  775.     short    UpRatioBytes;    /* 258 which set of file/byte ratios to use? */
  776.     short    UpChargeBytes;    /* 260 which set of charges to use?          */
  777.     short    UpRatioFiles;    /* 262 */
  778.     short    UpChargeFiles;    /* 264 */
  779.  
  780.     UBYTE    Invitation;    /* 266 */
  781.     UBYTE    UserMustJoin;
  782.     UBYTE    DeleteOwn;
  783.     UBYTE    Marker;        /* 0 = Base, 1 = UDBASE, &128 = Killed */
  784.  
  785.     long    Transforms;    /* 270 which BBSARCS to transform */
  786.  
  787.     char    NetPath[20];    /* 274 */
  788.     UBYTE    NetNumber;    /* 294 */ 
  789.     UBYTE    Locked;        /* 295 Does AMAINT have a lock here? */
  790.     UBYTE    DLnotifyULer;    /* 296 */
  791.  
  792.     char    Transform[5];    /* 297 */
  793.  
  794.     UBYTE    QWKReplies;    /* 302 */
  795.     BYTE    SBaseUse;    /* 303  which BBSCHARGE rate to use? */
  796.     UBYTE    CarbonCopy;    /* 304 */
  797.     UBYTE    CDROM;        /* 305 copy to hard drive before download? */
  798.  
  799.     struct    IsDate LastUpload;
  800.     struct    IsDate LastMessage;
  801.  
  802.     short    Users;        /* how many people are in this sub
  803.                    REAL TIME (not # of members) */
  804.  
  805.     long    Created;    /* for membership determination */
  806.  
  807.     short    Parent;        /* pointers to other subboard #s */
  808.     short    Child;
  809.     short    Next;
  810.  
  811.     short    TimeLock;    /* 330 minutes online before available */
  812. };
  813.  
  814. struct NewSubboardType {
  815.     char    Title[31];        /* 0  */
  816.     char    SubDirName[21];        /* 31 */
  817.     char    DataPath  [40];        /* 52 */
  818.     long    Parts;            /* 92 partitions 0-31 now allowed */
  819.  
  820.     long    SubOpIDs [6];        /* 96 */
  821.  
  822.     short    MRewardBytes;        /* 120 % of byte  size to award */
  823.     short    NRewardFiles;        /* 122 # of file creds to award
  824.                            uploader each time his file is
  825.                            downloaded */
  826.  
  827.     struct    FreeType *free0;    /* 124 */
  828.     long    nf_obs;            /* 128 */
  829.     long    nfmax_obs;        /* 132 */
  830.  
  831.     short    SubOpAccs[6];        /* 136 */
  832.  
  833.     char    Filler[6];        /* 148 shown during SCAN */
  834.  
  835.     UBYTE    fdelta;            /* 152 */
  836.     UBYTE    floaded;        /* 154 */
  837.  
  838.     UBYTE    Direct;            /* 156 Disk-exchange type */
  839.     UBYTE    Vote;            /* 157 May non-sysops add topics? */
  840.  
  841.     short    FreeDays;        /* 158 when files are auto-free */
  842.  
  843.     UBYTE    Subdirectory;
  844.     UBYTE    Closed;
  845.  
  846.     long    UnionFlags;        /* 162 Must have all of these flags */
  847.     long    Access;            /* 166 Groups which may ENTER */
  848.     long    PostAccess;        /* 170 Groups which may Post  */
  849.     long    RespondAccess;        /* 174 ... Respond */
  850.     long    UploadAccess;        /* 178 ... Upload */
  851.     long    DownloadAccess;        /* 182 ... Download */
  852.     long    ComputerTypes;        /* 186 */
  853.     long    Hours;            /* 190 restricted entry hours */
  854.     long    HourUnionFlags;        /* 194 */
  855.     long    HourAccess;        /* 198 groups which may Enter during Hours*/
  856.     long    Baud;            /* 202 minimum Baud rate to enter */
  857.     long    BaudHours;        /* 206 hours to enforce min baud rate */
  858.  
  859.     UBYTE    Gender;            /* 210 0 or 'M', 'F' */
  860.     UBYTE    AllowAliases;
  861.     UBYTE    PurgeStatus;        /* 212 */
  862.     UBYTE    Youngest;        /* 213 */
  863.  
  864.     UBYTE    EXTRA;
  865.  
  866.     UBYTE    Oldest;            /* 215 */
  867.  
  868.     struct    IsDate    Sent;        /* 216 FIDO to track new messages */
  869.  
  870.     short    MDownBytes;        /* 222 % of download bytes to subtract */
  871.     short    NDownFiles;        /* 224 # of files to subtract per download */
  872.     short    MTimeCredit;        /* 226 % of time to give back for uploads */
  873.  
  874.     long    MinFreeBytes;    /* 228 to upload in this subboard */
  875.     short    SubSort;    /* 232 */
  876.     short    InactiveDays;    /* 234 */
  877.  
  878.     UBYTE    RealNames;    /* 236 use real names instead of Handles? */
  879.     UBYTE    Addressees;
  880.     UBYTE    Anonymous;
  881.     UBYTE    override;    /* 239 how to set the use defaults flags in
  882.                     newly uploaded items */
  883.  
  884.     UBYTE    Verification;    /* 240 */
  885.     UBYTE    DupCheck;
  886.     UBYTE    ShowUnvalidated;
  887.     UBYTE    NoMCI;
  888.  
  889.     UBYTE    PrivateArea;    /* 244 0/1 No/Yes ... 2==FORCE */
  890.     BYTE    SDownFiles;    /* Which download charge schedules? */
  891.     BYTE    SDownBytes;
  892.     UBYTE    Test;        /* test at upload time */
  893.  
  894.     UBYTE    Transform;    /* 248 run script at upload time */
  895.     UBYTE    AutoAdopt;    /* Adopt Orphans at a-maint */
  896.     UBYTE    WeedResponses;    /* Use inactive days against indiv responses */
  897.     UBYTE    NoSignatures;
  898.  
  899.     UBYTE    NoReadCharges;    /* 252 opt to short circuit accounting system */
  900.     UBYTE    NoWriteCharges; /* 253 for reading/writing messages */
  901.  
  902.     long    Arcs;        /* 254 which Arcs in BBSARC are allowed uploaded*/
  903.  
  904.     short    UpRatioBytes;    /* 258 which set of file/byte ratios to use? */
  905.     short    UpChargeBytes;    /* 260 which set of charges to use?          */
  906.     short    UpRatioFiles;    /* 262 */
  907.     short    UpChargeFiles;    /* 264 */
  908.  
  909.     UBYTE    Invitation;    /* 266 */
  910.     UBYTE    UserMustJoin;
  911.     UBYTE    DeleteOwn;
  912.     UBYTE    Marker;        /* 0 = Base, 1 = UDBASE, &128 = Killed */
  913.  
  914.     long    Transforms;    /* 270 which BBSARCS to transform */
  915.  
  916.     long    ExportTo;    /* 274 */
  917.  
  918.     char    NothingNow[8];    /* 278 */
  919.  
  920.     long    count;        /* 286 replaces the _COUNT file */
  921.     long    hiwater;    /* 290 */
  922.  
  923.     UBYTE    NetNumber;    /* 294 */ 
  924.     UBYTE    Locked;        /* 295 Does AMAINT have a lock here? */
  925.     UBYTE    DLnotifyULer;    /* 296 */
  926.  
  927.     char    TransformTo[5];    /* 297 */
  928.  
  929.     UBYTE    QWKReplies;    /* 302 */
  930.     BYTE    SBaseUse;    /* 303  which BBSCHARGE rate to use? */
  931.     UBYTE    CarbonCopy;    /* 304 */
  932.     UBYTE    CDROM;        /* 305 copy to hard drive before download? */
  933.  
  934.     struct    IsDate LastUpload;
  935.     struct    IsDate LastMessage;
  936.  
  937.     short    Users;        /* how many people are in this sub
  938.                    REAL TIME (not # of members) */
  939.  
  940.     long    Created;    /* for membership determination */
  941.  
  942.     short    Parent;        /* pointers to other subboard #s */
  943.     short    Child;
  944.     short    Next;
  945.  
  946.     short    TimeLock;    /* 330 minutes online before available */
  947.  
  948.     char    ZeroPath[48];    /* 332 */
  949.     char    Origin  [60];    /* 380 */
  950.  
  951. /* if more room is needed, I could put all of this into a pointer to a
  952.    'sub-info' structure */
  953.  
  954.     short    MaxItems;    /* 440 */
  955.     UBYTE    Persist;    /* 442 */
  956.     UBYTE    Delay;        /* 443 */
  957.  
  958.     struct    ItemType3 *Item;
  959.     struct    ItemHeader *ihead;
  960.     struct    MessageType3 *NewMess;
  961.     struct    SignalSemaphore *sem;
  962.  
  963.     long    nm;        /* 460 # of _Messages */
  964.     short    rn;        /* 464 # of _Items */
  965.     short    AllocItems;
  966.     short    nNewMess;
  967.  
  968.     UBYTE    resetIP;    /* 470 */
  969.  
  970.     char    more_stuff[17];    /* 471 */
  971. };
  972.  
  973. /* LONG aligned.  Total length == 348 */
  974.  
  975. struct SerPort {
  976.     long    unit;        /* 0 */
  977.     long    flags;        /* 4 */
  978.  
  979.     short    idlebaud;    /* 8 */
  980.     short    escape;
  981.     short    answerpause;    /* 12 */
  982.     short    seconds;
  983.  
  984.     char    name[21];    /* 16 */
  985.     char    init1[50];
  986.     char    ppass[11];
  987.     char    init2[61];
  988.     char    hangup[21];
  989.     char    dialout[21];
  990.     char    answer[21];
  991.     char    offhook[21];
  992.     char    terminal[50];
  993.     char    callerid[11];
  994.     char    ring[9];
  995.     char    connect[11];
  996.  
  997.     char    termlink[21];    /* 324 */
  998.  
  999.     UBYTE    other[2];
  1000.  
  1001.     UBYTE    null;        /* local terminal, no clear line */
  1002. };
  1003.  
  1004. /* LONG aligned.  Total length == 20 */
  1005.  
  1006. struct    PortConfig {
  1007.     UBYTE    online;            /* port loaded or not */
  1008.     UBYTE    open;            /* 1==perm, 2==call only */
  1009.  
  1010.     UBYTE    check;            /* menus */
  1011.     UBYTE    idle;            /* clock, SAG, SAM ? */
  1012.  
  1013.     UBYTE    offline;        /* port loaded, but modem offline */
  1014.     UBYTE    not_used;
  1015.  
  1016.     UBYTE    bplanes;
  1017.     UBYTE    lace;            /* 0=none, 1=24 line, 2=49 line */
  1018.  
  1019.     USHORT    sizes[8];        /* workbench window & zoom size */
  1020. };
  1021.  
  1022. /* LONG aligned.  Total length==92 */
  1023.  
  1024. struct Privs {                /* each user&group has one */
  1025.     long    MBaseFlags;        /* 580 */
  1026.     long    FBaseFlags;        /* 584 Can user reach which subs ? */
  1027.     long    LBaseFlags;        /* 588 Gfiles/Pfiles flags */
  1028.  
  1029.     ULONG    ABits;            /* 592 see bitdefs above */
  1030.  
  1031.     long    DailyDownBytes;        /* 596 */
  1032.     long    DailyUpBytes;        /* 600 */
  1033.     long    XFreeBytes;        /* 604 !!! NOT USED ANYMORE !!! */
  1034.     long    XFreeFiles;        /* 608 SEE GLOBAL DEFAULT IN CONFIG1 */
  1035.  
  1036.     short    Calls;            /* 612 */
  1037.     short    CallMinutes;        /* 614 */
  1038.     short    DailyMinutes;        /* 616 */
  1039.     short    DailyDownloads;        /* 618 per 24 hr DAY */
  1040.     short    DailyUploads;        /* 620 same */
  1041.     short    Messages;        /* 622 */
  1042.     short    Feedbacks;        /* 624 */
  1043.     short    EditorLines;        /* 626 */
  1044.     short    Idle;            /* 628 */
  1045.     short    MaxMailKBytes;        /* 630 before mail-receive is limited */
  1046.     short    PurgeDays;        /* 632 */
  1047.  
  1048.     UBYTE    FileRatio;        /* 634 */
  1049.     UBYTE    ByteRatio;
  1050.     UBYTE    FileRatio2;
  1051.     UBYTE    ByteRatio2;
  1052.     UBYTE    FileRatio3;
  1053.     UBYTE    ByteRatio3;
  1054.  
  1055.     ULONG    ABits2;            /* 640 now gives 64 flags! */
  1056.  
  1057.     short    SigLines;        /* 644 how many lines per signature */
  1058.  
  1059.     UBYTE    AllowAliases;        /* 646 new tri-state variables */
  1060.     UBYTE    DeleteOwn;
  1061.     UBYTE    Anonymous;
  1062.     UBYTE    PrivateArea;
  1063.  
  1064.     short    DailyPfileMinutes;    /* 650 */
  1065.     short    LogToMail;        /* account # to send log */
  1066.  
  1067.     long    LogFlags;        /* 654 */
  1068.  
  1069.     UBYTE    CallBack;        /* 658 Tri-state */
  1070.     UBYTE    TermLink;        /* 659 */
  1071.     UBYTE    CallerID;        /* 660 */
  1072.     UBYTE    PageSysop;        /* 661 */
  1073.  
  1074.     char    exp[ 6 ];        /* 662 */
  1075.  
  1076.     short    Alias;            /* 668 */
  1077.     short    Dictionary;        /* 670 */
  1078. };
  1079.  
  1080. struct AccessGroup {
  1081.     char    Name[32];        /*   0 */
  1082.     struct    Privs DefPrivs;        /*  32 */
  1083.  
  1084.     short    ExpireDays;        /*  32+92 */
  1085.     UBYTE    ExpireAccess;        /*  32+94 */
  1086.  
  1087.     char    exp[29];
  1088. };
  1089.  
  1090. /* FILE: BBS.UKEYS3
  1091.    Alpha "key" for sortable data.  Phone# for caller-id, Handle/RealName
  1092.    for user addressing/mail/logon/etc.
  1093. */
  1094.  
  1095. struct KeyElement3 {
  1096.     char    UUCP[8];
  1097.     long    IDNumber;        /* high order byte ALWAYS 0 */
  1098.     long    phone1, phone2;        /* data phone's area code & local # */
  1099.     char    Handle   [21];
  1100.     char    RealName [26];
  1101.     UBYTE    PName;
  1102. };
  1103.  
  1104. struct OldKeyElement {
  1105.     char    Handle[22];        /* actual user handle */
  1106.     short    HandleX;        /* account number where found */
  1107. };
  1108.  
  1109. struct MarkType {
  1110.     short    sub;            /* The new system can uniquely  */
  1111.     long    ItemNumber;        /* identify a message with this */
  1112.     long    Seek;            /* information.  Used for Z/ZG. */
  1113.     long    Number;
  1114. };
  1115.  
  1116. struct TransType {
  1117.     struct    TransType *next;    /* linked list */
  1118.  
  1119.     long    lines;
  1120.     long    bytes;
  1121.  
  1122.     UBYTE    **mm;            /* pointers to BBSMENU lines */
  1123.     UBYTE    **bm;            /* pointers to BBSTEXT lines */
  1124.     short    menustart[50];        /* */
  1125.     short    menulen  [50];
  1126. };
  1127.  
  1128. struct NoiseType {
  1129.     struct    NoiseType *next;
  1130.  
  1131.     long    lines;
  1132.     long    bytes;
  1133.  
  1134.     char    **nn;
  1135.     char    *args;
  1136. };
  1137.  
  1138. struct MainPort {            /* common, public to all ports */
  1139.     struct    MsgPort mp;        /*   0 standard EXEC message port  */
  1140.     char    portName[22];        /*  34 */
  1141.  
  1142.     char    LastOn[32];        /*  56 */
  1143.  
  1144.     long    Nums[5];        /*  88 [0] # of physical user accounts
  1145.                            [1] # of in-use user accounts
  1146.                            [2] last assigned unique ID Number
  1147.                            [3] # of calls to system TOTAL
  1148.                            [4] # of calls now logged */
  1149.  
  1150.     ULONG    SAG[2][72];        /* 108 activity graph    */
  1151.     long    SAM[5][15];        /* activity monitor  */
  1152.     struct    IsDate SAMDate[6];    /* */
  1153.  
  1154.     long    um[10];            /* for C programmer use.  You can */
  1155.                     /* (typecast) them as you need to. */
  1156.                     /* Initially at bootup == 0 */
  1157.  
  1158.     struct    Window        *PWindow;
  1159.     struct    TransType    *FirstTT;
  1160.     struct    NewSubboardType *Subboard;
  1161.     struct    LinkPort    *link;    /* all-linked port users! */
  1162.     struct    KeyElement3    *Key;    /* alpha order, etc. */
  1163.     short    *IName;            /* Indexs into KeyElement3 array */
  1164.     short    *IPhone;
  1165.     char    *SubTitle;
  1166.     char    **Noise_00;        /* Conference NOISE memory */
  1167.     char    *NArg_00;        /* */
  1168.  
  1169.     long    ns;            /* number of subs in memory */
  1170.     long    nNOISElines_00;
  1171.     long    nNOISEbytes_00;
  1172.     long    YankCount;
  1173.     long    OpenPfiles;        /* */
  1174.  
  1175.     struct    NoiseType    *FirstNT;
  1176.  
  1177.     long    ClickMaint;        /* can we use local mouse maint? */
  1178.     long    Verbose;        /* do not redirect to NIL: for debug */
  1179.  
  1180.     long    s1;            /* version of CONTROL */
  1181.     long    s2;
  1182.     long    s3;            /* serial number of owner 0==DEMO */
  1183.  
  1184.     struct    BitMap  ClockBrush;    /* 40 bytes */
  1185.     struct    SignalSemaphore SEM[19];    /* for critical secs. */
  1186.     struct    AccessGroup     AGC[32];    /* BBS.ADATA stuff    */
  1187.  
  1188.     struct    Config1 gc;
  1189.  
  1190.     char    SysPassword[6][21];
  1191.     char    IDQ[6];            /* obs */
  1192.  
  1193.     struct    PortConfig  pc   [101];    /* For CONTROL, remembers things */
  1194.     struct    PortData   *PortZ[100];    /* pointers to each port's PortData struct */
  1195.     struct    Room       *CRoom[100];    /* pointers to ROOM structures  */
  1196.  
  1197.     struct    ULock *FirstULock;    /* Account Locking ... ! */
  1198.     short    LastTickHour;        /* control is ticking ... */
  1199.     short    LastTickMinute;
  1200.  
  1201.     short    HiPort;
  1202.     short    nPorts;
  1203.  
  1204.     char    regto[32], regco[32];
  1205. };
  1206.  
  1207. /* LONG Aligned, total length==672 */
  1208.  
  1209. struct UserData {            /* each user account */
  1210.     long    IDNumber;        /* 0 unique (serial) ID # */
  1211.     char    Handle[21];        /* 4 */
  1212.     char    RealName[26];        /* 25 */
  1213.     char    Address[31];        /* 51 */
  1214.     char    CityState[31];        /* 82 */
  1215.     char    ZipCode[11];        /* 113 */
  1216.     char    Country[8];        /* 124 */
  1217.     char    PhoneNo[17];        /* 132 Euro 8-7 format POSSIBLE!! */
  1218.     char    PassWord[15];        /* 149 */
  1219.     char    Comments[34];        /* 164 */
  1220.     char    Macro[3][36];        /* 198 user's defined macro keys */
  1221.     char    Organ[31];        /* 306 */
  1222.     UBYTE    PhoneVerified;        /* 337 */
  1223.  
  1224.     char    not_used[4];        /* 338 */
  1225.  
  1226.     struct    IsDate Birthdate;    /* 342 */
  1227.     struct    IsDate FirstCall;    /* 348 */
  1228.     struct    IsDate LastCall;    /* 354 */
  1229.  
  1230.     struct    IsDate NO_LONGER_USED;    /* 360 */
  1231.  
  1232.     struct    IsDate ConnectDate;    /* 366 */
  1233.     struct    IsDate YankDate;    /* 372 */
  1234.  
  1235.     BYTE    Access;            /* 378 */
  1236.     BYTE    ExpireAccess;        /* 379 */
  1237.  
  1238.     short    PfileTimeToday;
  1239.  
  1240.     short    not_used2;
  1241.  
  1242.     BYTE    TextSet;        /* 384 which BBSTEXT/MENU translation */
  1243.     BYTE    TimeForm;
  1244.     BYTE    MoreMode;
  1245.     BYTE    LineFeeds;
  1246.     BYTE    ObsParanoia;
  1247.     BYTE    TimeZone;
  1248.     BYTE    Colors;            /* can user display ANSI colors? */
  1249.     BYTE    Tabs;            /* can user do ANSI tabs? */
  1250.     BYTE    ANSI;            /* 392 */
  1251.     BYTE    Sex;
  1252.     BYTE    AutoMore;        /* More? and CLS between messages? */
  1253.     BYTE    TermType;
  1254.     BYTE    HelpLevel;        /* 396 */
  1255.     BYTE    CompType;
  1256.     BYTE    DefProtocol;        /* 398 */
  1257.     BYTE    TermWidth;
  1258.     BYTE    TermLength;        /* 400 */
  1259.     BYTE    MailBoxOpen;        /* 401 */
  1260.     short    MailForward;        /* 402 */
  1261.  
  1262.     long     TotalCalls;        /* 404 */
  1263.     long    PubMessages;        /* 408 */
  1264.     long    PriMessages;        /* 412 */
  1265.     long    UpBytes;        /* 416 KILO bytes */
  1266.     long    UpFiles;        /* 420 */
  1267.     long    DownBytes;        /* 424 KILO bytes */
  1268.     long    DownFiles;        /* 428 */
  1269.  
  1270.     long    FileCredits;        /* 432 CREDITS used now! */
  1271.     long    ByteCredits;        /* 436 */
  1272.     long    TimeCredits;        /* 440 */
  1273.  
  1274.     long    Balance;        /* 444 */
  1275.     long    NetCredits;        /* 448 */
  1276.     long    DoorPoints;        /* 452 */
  1277.  
  1278.     long    DayUpBytes;        /* 456 */
  1279.     long    DayDownBytes;        /* 460 */
  1280.     short    DayUpFiles;        /* 464 */
  1281.     short    DayDownFiles;        /* 466 */
  1282.  
  1283.     short    CallsToday;        /* 468 */
  1284.     short     TimeToday;        /* 470 */
  1285.     short    LogonAttempts;        /* 472 */
  1286.  
  1287.     USHORT    BaudRate;        /* 474 */
  1288.     USHORT    HighBaud;        /* 476 */
  1289.  
  1290.     char    UUCP[11];        /* 478 */
  1291.  
  1292.     UBYTE    PName;            /* 489 flags, are these data     */
  1293.     UBYTE    PAge;            /* items to be kept private? */
  1294.     UBYTE    PAddress;        /* street address only */
  1295.     UBYTE    PVoice;            /* phone numbers */
  1296.     UBYTE    PData;
  1297.  
  1298.     char    Banner[43];        /* 494 */
  1299.  
  1300.     char    VoiceNo[17];        /* 537 Euro 8-7 format POSSIBLE!! */
  1301.  
  1302.     short    YankCount;        /* 554 */
  1303.  
  1304.     struct    IsDate ExpireDate;    /* 556 */
  1305.     struct    IsDate FNewDate;    /* 562 */
  1306.  
  1307.     char    more[7];        /* 568 reserved */
  1308.  
  1309.     UBYTE    YankCR;            /* 575 add CR's to yank text? */
  1310.     UBYTE    YankArc;        /* which archiver to use? */
  1311.     BYTE    DefEditor;        /* 577 */
  1312.     BYTE    AutoHide;
  1313.     BYTE    PrivsSet_NOT;        /* 579 */
  1314.     struct    Privs MyPrivs;        /* 580 THESE ACTUALLY USED, not AGC */
  1315. };
  1316.  
  1317. struct OLMHeader {
  1318.     char    ByUser[26];        /* actual handle only */
  1319.     short    ByAccount;
  1320.     short    Port;
  1321.  
  1322.     UBYTE    system;
  1323.     UBYTE    broadcast;
  1324.  
  1325.     UBYTE    other[22];
  1326. };
  1327.  
  1328. /* length == 296 */
  1329.  
  1330. struct MailHeader {            /* NEW 2.0 for mail, etc */
  1331.     struct    IsDate  Date;
  1332.     struct    IsDate    EDate;        /* for EXPIRATION setting */
  1333.     short    EDays;
  1334.     char    Subject [81];        /* Ahh, nice and roomy */
  1335.     char    From    [27];
  1336.  
  1337.     long    Number;
  1338.  
  1339.     short    ByAccount;
  1340.     long    ByID;
  1341.  
  1342.     char    To    [28];        /* originals, if was Sent/forwarded */
  1343.     long    ToID;
  1344.     short    ToAccount;
  1345.  
  1346.     UBYTE    Receipt;        /* return-receipt ?? */
  1347.     UBYTE    Return;            /* return original message?? */
  1348.  
  1349.     UBYTE    HasOriginal;        /* is original attached to this one? */
  1350.     UBYTE    File;            /* for File Mail */
  1351.     UBYTE    Anonymous;        /* From an anonymous user? */
  1352.  
  1353.     char    Route    [41];        /* for Bulk Mail, list of recips */
  1354.     short    Recipients;        /* number of recipients ... */
  1355.     UBYTE    Party;            /* Allow party responses? */
  1356.  
  1357.     long    Length;
  1358.     long    CheckSum;        /* must be 0 */
  1359.  
  1360.     long    Item;            /* if this message is repeated */
  1361.     long    Seek;            /* somewhere on the system     */
  1362.     short    Base;            /* this tells where !!!        */
  1363.  
  1364.     char    NetAddress[52];        /* may be shortened */
  1365.  
  1366.     UBYTE    Alias;
  1367.     UBYTE    Replied;
  1368.     UBYTE    Received;
  1369.     UBYTE    NoEdits;
  1370.  
  1371.     struct    IsDate  ShowDate;
  1372. };
  1373.  
  1374. /* LONG aligned.  Length==172 */
  1375.  
  1376. struct Subdirectory {
  1377.     long    SubOpIDs [10];
  1378.     short    SubOpAccs[10];
  1379.  
  1380.     long    Access;
  1381.     long    UnionFlags;
  1382.  
  1383.     long    Hours;
  1384.     long    HourUnionFlags;
  1385.     long    HourAccess;
  1386.  
  1387.     long    Baud;
  1388.     long    BaudHours;
  1389.  
  1390.     short    Youngest;
  1391.     short    Oldest;
  1392.  
  1393. /* when the Download command is used on a Gfile */
  1394.  
  1395.     short    NDownFiles;    /* # of download files to subtract */
  1396.     BYTE    SDownFiles;    /* Which download charge schedules? */
  1397.     BYTE    SDownBytes;
  1398.  
  1399. /* per-usage charge schedules from BBSCHARGESX.A files */
  1400.  
  1401.     long    unused;
  1402.  
  1403.     UBYTE    Gender;        /* 0 or 1, 2 */
  1404.     UBYTE    SBaseUse;    /* accounting schedule for this area */
  1405.     UBYTE    Closed;
  1406.  
  1407.     UBYTE    exp[61];
  1408.  
  1409.     long    ComputerTypes;
  1410.  
  1411.     short    TimeLock;    /* minutes online before available */
  1412.     short    MDownBytes;    /* % of download Bytes to subtract */
  1413. };
  1414.  
  1415. struct ListItem {
  1416.     short    Version;        /* should be 225 */
  1417.     char    Path       [54];    /*   2 */
  1418.     char    Description[64];    /*  56 */
  1419.     char    Arguments  [64];    /* 120 */
  1420.  
  1421.     long    Access;            /* 184 */
  1422.     long    UnionFlags;        /* 188 */
  1423.  
  1424.     struct    IsDate Date;        /* 192 */
  1425.  
  1426.     short    SCharge;        /* 198 accounting use-of-item charge */
  1427.  
  1428.     UBYTE    Subdirectory;        /* 200 */
  1429.     UBYTE    FifoFlags;        /* 201 1==RAW startup */
  1430.     UBYTE    ReadFlags;        /* internal only */
  1431.     UBYTE    Environ;
  1432.  
  1433.     UBYTE    DailyPfileTime;        /* 204 subtract from daily pfile time? */
  1434.     UBYTE    Disabled;        /* 205 */
  1435.     UBYTE    Type;            /* 206 not really used yet */
  1436.     UBYTE    PurgeKill;        /* 207 Delete item when purged? */
  1437.  
  1438.     UBYTE    Expansion[14];        /* 208 */
  1439.  
  1440.     struct    IsDate PurgeDate;    /* 222 */
  1441. };
  1442.  
  1443. /* Length== 176 */
  1444.  
  1445. struct OldListItem {
  1446.     char    Path       [51];    /* 0 */
  1447.     char    Description[61];    /* 51 */
  1448.     char    Arguments  [20];
  1449.  
  1450.     struct    IsDate Date;        /* 132 */
  1451.  
  1452.     long    Access;            /* 138 un-al */
  1453.  
  1454.     UBYTE    Subdirectory;        /* 142 */
  1455.     UBYTE    DaysToKeep;
  1456.     UBYTE    ReadFlags;        /* internal only */
  1457.     UBYTE    Environ;
  1458.  
  1459.     short    SCharge;        /* 146 override a subdir schedule */
  1460.  
  1461.     long    UnionFlags;
  1462.  
  1463.     UBYTE    DailyPfileTime;        /* subtract from daily pfile time? */
  1464.  
  1465.     UBYTE    Expansion[23];        /* 148 */
  1466. };
  1467.  
  1468. /* LONG aligned.  Length==48 */
  1469.  
  1470. struct CPort {                /* setup when a C pfile is ran */
  1471.     struct    MsgPort  mport;        /* 0 */
  1472.     short    align;
  1473.     struct    MainPort *myp;        /* 36 pointer to MainPort */
  1474.     struct    PortData *zp;        /* 40 pointer to my PortData */
  1475.  
  1476.     UBYTE    ack;            /* 44 tell CNet we've arrived */
  1477.     UBYTE    align2[3];
  1478. };
  1479.  
  1480. struct CMessage {            /* passed between C pfile and C-Net */
  1481.     struct    Message cn_Message;    /* 0 communication stuff */
  1482.     ULONG    arg1;            /* 20 */
  1483.     ULONG    arg2;
  1484.     ULONG    arg3;
  1485.     ULONG    arg4;
  1486.     ULONG    result;
  1487.     UBYTE    command;        /* 40 which command? see programming doc */
  1488.     UBYTE    align[3];
  1489. };
  1490.  
  1491. struct Event {
  1492.     long    Start;
  1493.     long    End;
  1494.  
  1495.     short    Event;
  1496.     char    Args[82];
  1497.     long    IntArgs;
  1498.  
  1499.     struct    Event *Next;
  1500. };
  1501.  
  1502. struct ConfigEvent {
  1503.     char    Ports[40];
  1504.  
  1505.     UBYTE    Days;        /* if this is 0, use Date */
  1506.     char    Date[7];
  1507.  
  1508.     short    Time,
  1509.         Duration,
  1510.         Interval,
  1511.         Iterations;
  1512.  
  1513.     short    Event;
  1514.     char    Args[81];
  1515.  
  1516.     UBYTE    Type;
  1517. };
  1518.  
  1519. /* all LONG's 4 byte aligned */
  1520.  
  1521. struct PortData {            /* each opened ports global vars */
  1522.     struct    IsDate    Today;        /* 0 what time is it right now? */
  1523.     struct    IsDate    VConnectDate;    /* 6 Virtual connect...eg 12am */
  1524.  
  1525.     short    id,            /* 12 current user1 account # */
  1526.         InPort,            /* 14 which port are we in??  */
  1527.         Age,            /* 16 how old am I ? */
  1528.         CurrentCPS,        /* 18 CPS rate.  240 == 2400 baud */
  1529.         OnType,            /* 20 type of logon  */
  1530.         OffType,        /* 22 */
  1531.         CallMessages,        /* 24 */
  1532.         CallFeedbacks,        /* 26 */
  1533.         TimeLeft,        /* 28 TENTHS of minutes left */
  1534.         TimeIdle,        /* 30 TENTHS of minutes without activity */
  1535.         TimeOnLine,        /* 32 TENTHS of minutes since logon */
  1536.         TimeCredit,        /* 34 TENTHS awarded for uploads, etc */
  1537.         LastTSR,        /* 36 */
  1538.         Carrier;        /* 38 Is there a carrier or Local? */
  1539.  
  1540.     char    *AName;            /* 40 ptr to access group name */
  1541.     long    SysMaint,        /* 44 */
  1542.         LocalTime,        /* 48 current area sur-time minutes */
  1543.         LocalCharge,        /* 52 current area sur-charge per minute */
  1544.         LastTime,        /* 56 */
  1545.         ServLen,        /* 60 seconds in-between Service() calls */
  1546.         Caller;            /* 64 which caller am I? */
  1547.  
  1548.     struct    UserData    user1,    /* 68 */
  1549.                 user2;    /* 740 actual user structs */
  1550.  
  1551.     short    MyMail;            /* 1412 counters for user currently online */
  1552.     short    MyNewMail;        /* 1414 */
  1553.     short    bn;            /* 1416 current sub # */
  1554.  
  1555.     char    CallerID [18];        /* 1418 Received from Supra, prev connect */
  1556.     short    CIDmatch [ 8];        /* Accounts which MATCH, [0] will be current user  */
  1557.  
  1558.     UBYTE    expansion[18];        /* 1436 */
  1559.  
  1560.     UBYTE    PAccess,        /* 1470 */
  1561.         RAccess,
  1562.         DAccess,
  1563.         UAccess;
  1564.  
  1565.     char    fsuff[8],        /* 1474 more header stuff */
  1566.         fcore[32],        /* 1482 */
  1567.         Title[80],        /* 1514 Screen/Window */
  1568.         lastby[36];        /* 1594 */
  1569.  
  1570.     UBYTE    IUCBits[100];        /* 1630 Hidden, Muffled, Monitor, ChatReq */
  1571.  
  1572.     char    *MyDoing;        /* 1730 */
  1573.     struct    Room *CRoom;        /* 1734 which room am I in ? */
  1574.     struct    RoomUser *CUser;    /* 1738 where is my RoomUser struct */
  1575.  
  1576.     UBYTE    Dumped,            /* 1742 auto-kickoff flag    */
  1577.         OLMWaiting,        /* 1743 OLM waiting        */
  1578.         HideAll,        /* 1744 Hidden from ALL?    */
  1579.         MuffAll,        /* 1745  Muffling ALL?    */
  1580.         MonitorAll,        /* 1746 Monitoring ALL?    */
  1581.         OnLine,            /* 1747 */
  1582.         nPdepth,        /* 1748 How many pfiles a port is running */
  1583.         ChatCode,        /* 1749 who's chatting with whom */
  1584.         WantToOpen,        /* 1750 */
  1585.         getout,            /* 1751 flag to auto-quit port */
  1586.         loaded,            /* 1752 Is this port loaded? */
  1587.         other[3];        /* 1753 */
  1588.  
  1589.     long    LastEvent,        /* 1756 keep track of the last event */
  1590.         LastCut,        /* 1760 time in these 4 catagories */
  1591.         LastHold,        /* 1764 */
  1592.         LastOnLine;        /* 1768 */
  1593.  
  1594.     long    TempSysMaint;
  1595.     short    ConfIdle;
  1596.  
  1597.     UBYTE    expansion2[16];        /* 1772 */
  1598.  
  1599.     ULONG    DOIO_MASK;         /* 1794 */
  1600.     struct    IOStdReq     *DoReq;     /* 1798 */
  1601.     struct    MsgPort        *DoPort; /* 1802 */
  1602.  
  1603.     long    uz[10];            /* 1806 for C programmer use.  You can */
  1604.                     /* (typecast) them as you need to */
  1605.  
  1606.     struct    Task        *ThisTask;
  1607.     struct    MainPort    *cnp;
  1608.  
  1609.     struct    Window        *Window, *CWindow, *SWindow, *TWindow,
  1610.                 *TTWindow, *WBWindow;
  1611.     struct    Screen        *Screen;
  1612.     struct    RastPort    *wrp, *trp;
  1613.     struct    TextFont    *BlueFont,
  1614.                 *StandardFont;
  1615.     struct    IOStdReq     *UTReq, *ServReq, *PrintReq, *ConReq;
  1616.     struct    IOExtSer    *SerRdReq, *SerWrReq, *SerIOReq;
  1617.     struct    MsgPort        *SerRdPort,*SerWrPort,*SerIOPort, *ConPort,
  1618.                 *UTPort,   *ServPort, *PrintPort, *cpreplyp;
  1619.  
  1620.     struct    FileInfoBlock    *fib;    /* for reading directories */
  1621.     struct    InfoData    *IData;    /* for getting free disk space, etc */
  1622.     struct    ItemType3       *Item_obs;
  1623.     struct    MessageType3    *Message;
  1624.     struct    BaseUser    *buser;
  1625.     struct    SelectType      *Select;
  1626.     struct    BaseUser    *brec;
  1627.     struct    SelectType    *Upload;
  1628.     struct    ListItem        *fpt;
  1629.     struct    ItemHeader    **ih, *ihead_obs;
  1630.     struct    ItemType3    **ip;
  1631.     char    **EdBuffer;        /* pointers to editor lines.*/
  1632.     char    *EdBase;        /* pointer to editor memory */
  1633.     UBYTE    *CR;            /* Is there a Carriage Return? ea line*/
  1634.     char    **mm;            /* pointers to bbsmenu lines */
  1635.     char    **bm;            /* pointers to bbstext lines */
  1636.     short    *menustart;
  1637.     short    *menulen;
  1638.  
  1639.     long    plsize, nplanes;    /* SkyStuff Stuff */
  1640.     short    skyxpen, skyypen;
  1641.     PLANEPTR planePtr;
  1642.     struct    TmpRas        tmpRas;
  1643.     struct    BitMap      SkyBrush;
  1644.  
  1645.     long    FullMaint;
  1646.  
  1647.     long    numWE;            /* window-edit, current number */
  1648.     long    WWidth;        /* 80 */
  1649.     long    WLength;    /* 24 */
  1650.     long    WLeft;        /* def   0 */
  1651.     long    WRight;        /* def 639 */
  1652.     long    WTop;        /* def  11 */
  1653.     long    WBottom;    /* def YMAX */
  1654.  
  1655.     short    xc,            /* x coord, cursor pos */
  1656.         yc,            /* y coord */
  1657.         sxc,            /* storage for ANSI [s, [t */
  1658.         syc,
  1659.         YMAX,            /* max y value */
  1660.         CurrentMouseX,
  1661.         CurrentMouseY,
  1662.         countWE;        /* window-edit, # characters */
  1663.  
  1664.     short    IsHalfScreen;
  1665.     short    TermLength;
  1666.  
  1667.     short    SWidth;
  1668.     short    SHeight;
  1669.     short    DWidth;
  1670.     UBYTE    io_bad;
  1671.     UBYTE    io_status;        /* debugging Supra hangs */
  1672.  
  1673.     char    *by0,            /* scan and header variables */
  1674.         *by1,            /* for MCI configurability */
  1675.         *to0,
  1676.         *to1,
  1677.         *date0,
  1678.         *organ,
  1679.  
  1680.         plus[2],
  1681.         star[2],
  1682.         fdate[8],
  1683.         fsize[8],
  1684.         ftime[12],
  1685.         *title0,
  1686.         *olm_default,
  1687.         *vis_subj,
  1688.         *vis_to,
  1689.         *user_default,
  1690.         *subj_default;
  1691.  
  1692.     short    Depth;
  1693.     short    DHeight;
  1694.  
  1695.     short    TextSet;        /* 0==use system-wide text/menu */
  1696.     short    npitems;        /* number of items parsed */
  1697.     char    pitem[8][61];        /* last input parsed list */
  1698.  
  1699.     long    txline;            /* number of lines in ed buffer */
  1700.     char    GBuffer[16][81];    /* General purpose 2-D text buffer */
  1701.     UBYTE    GCR[16];
  1702.  
  1703.     ULONG    WaitFlags,
  1704.         SERVICE_MASK,
  1705.         RAWKEY_MASK;
  1706.  
  1707.     short    ACC[80],        /* accounting table currently in use */
  1708.         nowCharge;        /* schedule now in memory            */
  1709.  
  1710.     long    CTC[80];        /* users account, 62 items, Cost of This Call */
  1711.  
  1712.     short    sorder[240];        /* max subboards per subdir is 240 */
  1713.  
  1714.     char    *LastError;        /* for file transfer WHY command */
  1715.  
  1716.     char    RexxObject  [100],
  1717.         KBuff       [256],    /* keyboard buffer! */
  1718.         ABuffer     [256],    /* workspace */
  1719.         InBuffer    [256],    /* after a line input */
  1720.         FileNote    [364],
  1721.         Doing         [48],
  1722.         SPrompt     [128],    /* subboard prompt */
  1723.         LPrompt     [128],    /* G/P/N list prompt */
  1724.         diskloc_obs  [80],
  1725.         ldiskloc     [80],    /* diskloc for P/G/N */
  1726.         myloc        [80],
  1727.         LastSubject_obs  [84],    /* for Read-Mail */
  1728.         filename    [116],
  1729.         ListArea     [40],
  1730.         rsearch      [64],
  1731.         myfile       [54],
  1732.         dirname      [32],
  1733.         CStack       [80],    /* Command stacking */
  1734.         ChatMsg      [84],    /* current chat message */
  1735.         sbuff        [48],
  1736.         outbuffer    [84],
  1737.         ansiout      [164],
  1738.         ConnectCode  [84],
  1739.         ChatBuff     [84],
  1740.         APrint       [36],    /* for PrintAccess */
  1741.         PName     [3][32],
  1742.         home         [36],
  1743.         qwk_to       [28],
  1744.         qwk_subject  [28],
  1745.         BackBuff [10][80],    /* last 10 commands executed */
  1746.         Pathx     [8][64];    /* g/p/n subdir history */
  1747.  
  1748.     long    bbnum;            /* pointer into D-Q */
  1749.  
  1750.     long    warn1;
  1751.  
  1752.     long    TotalCTC;        /* TOTAL Cost of this Call (100ths)*/
  1753.  
  1754.     short    bz,        /* # of subs on current List */
  1755.         dz,        /* how deep in the tree are we? */
  1756.         br,        /* item last used */
  1757.         rn_NOT,        /* how many items, current list */
  1758.  
  1759.         nl,        /* number on g/p/n list */
  1760.         allin_NOT,    /* Are all items in memory? */
  1761.         VTimeOnLine,    /* may reset at midnight */
  1762.         PTimeOnLine,    /* in-current-pfile time counter */
  1763.  
  1764.         mx,        /* highest item NOT killed */
  1765.         listn,        /* current list subboard pointer */
  1766.         parent0,
  1767.         gpos,        /* for global commands, last command # */
  1768.  
  1769.         nsubs,        /* tracks # subs accessed in a Global cmd */
  1770.         LinkPort;
  1771.  
  1772.     long    TermLinkBaud;
  1773.  
  1774.     long    nm_NOT,        /* were once SHORTS...moved here to*/
  1775.         rs,        /* avoid conflicts with 32767 max  */
  1776.         cpos,
  1777.         mstart,
  1778.         mend,
  1779.         new_i,        /* responses/item or per subboard  */
  1780.         new_n,
  1781.         new_f,
  1782.         new_p,
  1783.         new_ri,
  1784.         t_new_i,    /* total new items */
  1785.         t_new_n,    /* total new messages to you */
  1786.         t_new_f,    /* total new files */
  1787.         t_new_p,    /* total new posts */
  1788.         t_new_ri;    /* total new response items */
  1789.  
  1790.     short    AParams,
  1791.         AParam[17];
  1792.  
  1793.     UBYTE    qwk;
  1794.     UBYTE    ylharc;
  1795.     UBYTE    yaddcr;
  1796.     UBYTE    ylocal;
  1797.  
  1798.     short    zmatches;
  1799.     UBYTE    zheader;
  1800.     UBYTE    readnew;
  1801.  
  1802.     long    nsets,
  1803.         rset,
  1804.         rcount,
  1805.         rtotal,
  1806.         set[10][2];
  1807.  
  1808.     UBYTE    runseen,
  1809.         resetIP,        /* flag, must re-order item pointers */
  1810.         atbase,
  1811.         TermLink,
  1812.  
  1813.         rtome,
  1814.         rfree,
  1815.         rfavorite,
  1816.         runval,
  1817.  
  1818.         rprivate,
  1819.         rreverse,
  1820.         rbrandnew,
  1821.         rnresponse,
  1822.  
  1823.         rpass,
  1824.         rsince,
  1825.         rnew,
  1826.         rglobal,
  1827.  
  1828.         rdeftype,
  1829.         rchron,
  1830.         rbyme,
  1831.         runtil,
  1832.  
  1833.         rjustposts,
  1834.         rpreview,
  1835.         rbanner,
  1836.         rjustfiles;
  1837.  
  1838.     struct    IsDate    rdate,
  1839.             udate;
  1840.  
  1841.     short    pos,
  1842.         num,
  1843.  
  1844.         rdelta,        /* for/back n items */
  1845.  
  1846.         NoSelected,    /* number of items in Select List */
  1847.         NoUploaded,
  1848.         ModelType;        /* Controls .M in editor.  */
  1849.  
  1850.     struct    RangeContext EdRange;
  1851.  
  1852.     long    tline, bit_mci;
  1853.     short    times, repmode, MaxLines, WScroll;
  1854.  
  1855.     long    warn2;
  1856.  
  1857.     char    keyin,
  1858.         edall_not,        /* allow enterline all chars */
  1859.         serbuffer[2];
  1860.  
  1861.     UBYTE    mode,
  1862.         ZAlternate,
  1863.         CheckAllEvents,        /* force check of TimeTilEvent's */
  1864.         TrapDoor,
  1865.  
  1866.         AtPrompt,
  1867.         InShell,
  1868.         donormal,
  1869.         dtr,        /* modem device OPENED and ready */
  1870.  
  1871.         sread,        /* read request pending ... */
  1872.         modem,        /* modem exists ... allows BBSPORT0 */
  1873.         mio,        /* modem IO allowed */
  1874.         isud,        /* when in base, is UD, not BASE */
  1875.  
  1876.         MaxColors,        /* # of colors on screen */
  1877.         FlagCH,
  1878.         FlagED,
  1879.         Gflag,
  1880.  
  1881.         ConfMode,        /* Are we in conference? */
  1882.         column,
  1883.         KB1,            /* DeQueue pointers */
  1884.         KB2,
  1885.  
  1886.         KB3,            /* what inter-user chat sees */
  1887.         CursorStatus,        /* is cursor on? */
  1888.         AbortFlags,
  1889.         HourNow,
  1890.  
  1891.         LastHour,
  1892.         Indent,
  1893.         InANSI,
  1894.         GETarg,
  1895.  
  1896.         CMDarg,
  1897.         LocalMode,        /* BOOLS .. In Local Mode ? */
  1898.         noflowcontrol,
  1899.         AtWaitScreen,        /* Are we at IDLE? */
  1900.  
  1901.         InMCI,
  1902.         DoQuick,        /* ! at last input ? */
  1903.         AutoLogon,
  1904.         TermOn,            /* in terminal? */
  1905.  
  1906.         ANSIon,            /* can we type ansi? (ESC) */
  1907.         PrintFlags,        /* space or ^C pressed */
  1908.         CountUp,
  1909.         InputFlags,
  1910.  
  1911.         Relogon,
  1912.         Logoff,
  1913.         NewScanBROWSE,        /* BROWSE at logon scan for new? */
  1914.         AutoScroll,
  1915.  
  1916.         WWrap,
  1917.         DoubleBuffer,
  1918.         MoreRow,
  1919.         MoreAtRow,
  1920.  
  1921.         WScreen,
  1922.         InTransfer,
  1923.         NoMCI,
  1924.         FreezeTime,
  1925.  
  1926.         kolorific,
  1927.         mciflash,        /* actually, bold */
  1928.         mciscore,
  1929.         mcireverse,
  1930.  
  1931.         intense,        /* color greater than 7? */
  1932.         mciprint,
  1933.         mcispeed,
  1934.         mcicolor,        /* the requested MCI color 0-7 */
  1935.  
  1936.         pencolor,        /* actual screen pencolor */
  1937.         mcinoabort,
  1938.         backcolor,        /* background color */
  1939.         mciback,
  1940.  
  1941.         MCIenv,            /* current MCI environ flags */
  1942.         MCIdefenv,
  1943.         MRinuse,
  1944.         OffLine,        /* skip answering the phone?? */
  1945.  
  1946.         cminute, 
  1947.         chour,
  1948.         FNewSave,        /* flag: update FNewDate at logoff */
  1949.         intab;            /* for LoadLine() */
  1950.  
  1951.     char    mcitest,        /* MCI stuff */
  1952.         EditorOn,        /* is editor on? */
  1953.         var5,
  1954.         ScreenWidth;
  1955.  
  1956.     long    warn3;
  1957.  
  1958.     long    swrite, LogoffFlag;    /* file transfer stuff */
  1959.     long    ResumeSize;
  1960.     short    ResumeNumber, StartUpTime;
  1961.  
  1962.     short    protonum;
  1963.     char    protobyte;
  1964.     char    edbuff;            /*  1 saved new text
  1965.                         0 saved empty buffer
  1966.                        -1 aborted
  1967.                     */
  1968.  
  1969. /* If you use QuoteType=2, you MUST set the following three variables.
  1970.    Note that QuoteFrom and QuoteDate are POINTERS ... do NOT copy into
  1971.    them!
  1972. */
  1973.     char    *QuoteFrom;        /* Who are we quoting? */
  1974.     struct    IsDate *QuoteDate;    /* When was that message written? */
  1975.     long    QuoteEnd;        /* LAST BYTE position in file */
  1976.                     /* Quoter will stop automatically
  1977.                        if ^Z occurs first */
  1978.     UBYTE    qwk_anonymous;
  1979.     UBYTE    qwk_private;
  1980.     short    xfercount;
  1981.  
  1982.     long    XferTime;
  1983.     long    LastCPS, cpsavecount;
  1984.     long    cpsavesum, LastXTime, StartByte, LastByte;
  1985.  
  1986.     short    ARunCount;        /* depth of AREXX pfiles */
  1987.     short    CRunCount;        /* depth of C pfiles */
  1988.     char    CSpawn[84];
  1989.  
  1990.     long    TrapBaud;
  1991.     long    TrapLock;
  1992.  
  1993.     UBYTE    QuoteType;        /* 0==Mail, 1==Message base
  1994.                        2==User defined.  See QuoteFrom,
  1995.                           QuoteDate, etc., above */
  1996.     char    QuotePath[103];        /* MESSAGE QUOTING in editor. */
  1997.                     /* SETTING this ENABLES quoting.
  1998.                        Remember to QuotePath[0] = 0 after
  1999.                        you use it. */
  2000.     long    QuoteSeek;        /* What's the starting byte pos? */
  2001.  
  2002.     short    imode;        /* editor.  Insert mode?  If yes, which line*/
  2003.     short    iline;
  2004.  
  2005.     long    abort;
  2006.  
  2007.     short    UrgentMail1;
  2008.     char    ExtTransfer;
  2009.     char    ExtProtocol;
  2010.  
  2011.     long    ExtMinFree;
  2012.  
  2013.     long    ALogon;
  2014.     long    BLogon;
  2015.     long    ATransfer;
  2016.     long    BDownload;
  2017.     long    BUpload;
  2018.     long    APfiles;
  2019.     long    BCharge;
  2020.     long    hiCharge;
  2021.     long    loCharge;
  2022.  
  2023.     long    rtoid;            /* to 'handle' searches */
  2024.  
  2025.     long    TimeTilOnLine,
  2026.         TimeTilCutoff,        /* Log user off first event */
  2027.         TimeTilEvent,        /* Immediate (regular) event */
  2028.         TimeTilHold;        /* hold until off-line event */
  2029.  
  2030.     long    SERIAL_MASK,
  2031.         UTILITY_MASK;
  2032.  
  2033.     char    *xpr_filename;
  2034.  
  2035.  
  2036.     UBYTE    xpr_obsolete[124];
  2037.  
  2038.  
  2039.     struct    MsgPort *rexxPort;
  2040.     long    rexxPortBit;
  2041.     char    *extension;
  2042.     struct    rexxCommandList *globalrcl;
  2043.  
  2044.     UBYTE    callback,        /* enable AUTOCALLBACK @ LOGON */
  2045.         avalid,            /* which avalid set to use */
  2046.         joinlink,        /* 0==off, 1==accept, 2==accept ONLY */
  2047.         FreezeIdle;        /* special use -- stop idle timer */
  2048.  
  2049.     long    rbyid;            /* by 'handle' searches */
  2050.  
  2051.     long    SAMNow[20];        /* users 'Last' SAM column */
  2052.  
  2053.     struct    CMessage    cpmess;
  2054.     struct    SerPort        sp;    /* BBSPORT data. see above struct */
  2055.     struct    BaseUser    xbrec;
  2056.     struct    ItemType3    Item0;
  2057.     struct    ItemHeader    ihead0;
  2058.     struct    HeaderType    Header0, LastHeader;
  2059.     struct    MailHeader    Mail0;
  2060.     struct    SelectType    Select0;
  2061.     struct    MessageType3    Message0;
  2062.     struct    Subdirectory    sub;
  2063.  
  2064.     struct    NewSubboardType *sb;
  2065.  
  2066.     char    rpattok[202];        /* tokenized search pattern */
  2067.  
  2068.     UBYTE    Subboard0_NOT [276];
  2069.  
  2070.     short    WBorTop;
  2071.     short    nupload;        /* # of upload allocated    */
  2072.     short    nips;            /* # of ip,ih now allocated */
  2073.  
  2074.     short    Monitored;        /* 128 + port number if monitored. */
  2075.     short    ModelEnable;        /* Controls .M in editor.  */
  2076.  
  2077.     BPTR    MCIfile;
  2078.     long    mcilabel;
  2079.     long    nlabels;
  2080.     long    mlabel[20];
  2081.     long    mfseek[20];
  2082.     long    MCInreg[10];
  2083.     char    MCIcreg[ 5][100];
  2084.  
  2085.     BPTR    sf;            /* for _short scan */
  2086.     long    sfin;
  2087.  
  2088.     long    VoteItem;        /* which vote? -1==New */
  2089.     char    *VotePath;        /* for Vote in Any Area! */
  2090.  
  2091.     UBYTE    q_kolorific,        /* MCI Q2/Q3 storage */
  2092.         q_mciflash,
  2093.         q_mciscore,
  2094.         q_mcireverse,
  2095.  
  2096.         q_intense,
  2097.         q_mciprint,
  2098.         q_mcispeed,
  2099.         q_mcicolor,
  2100.  
  2101.         q_mciback,
  2102.         q_mcinoabort,
  2103.         q_MCIenv;
  2104.  
  2105.     UBYTE    SelectInMemory;        /* is _select in memory or on disk? */
  2106.  
  2107.     struct    Event    *FirstEvent,
  2108.             *FirstCutEvent,
  2109.             *FirstHoldEvent,
  2110.             *FirstOnLineEvent;
  2111.  
  2112.     struct    TermLink tl;
  2113.  
  2114.     char    JoinLinkOut[76];
  2115.  
  2116.     struct    VDEentry *vv;        /* the currently loaded VDE file */
  2117.     short    vns;            /* used with VDEapply featuers!  */
  2118.     UBYTE    vmulti;            /* editing more than one?        */
  2119.     UBYTE    iselect;        /* is the input SELECTED?        */
  2120.  
  2121.     char    gmFile[40];        /* global Read-Mail variables... */
  2122.     long    *gmPos;            /* needed for Yank command ....  */
  2123.     UBYTE    *gmFlags;
  2124.  
  2125.     UBYTE    *amem;            /* DrawEd variables */
  2126.     UBYTE    *cmem;
  2127.     long    maxdraw;
  2128.  
  2129.     UBYTE    predraw;
  2130.     UBYTE    hmmmm[3];
  2131.  
  2132.     UBYTE    *smem;
  2133.  
  2134.     long    inlen, edlength;
  2135. };
  2136.  
  2137. #define HIDDEN_FLAG    0x01
  2138. #define MUFFLED_FLAG    0x02
  2139. #define MONITOR_FLAG    0x04
  2140. #define CHATREQ_FLAG    0x08
  2141.  
  2142. struct ULock {                /* account locking node!!! */
  2143.     short    Account;
  2144.     short    Wait;
  2145.  
  2146.     struct    SignalSemaphore Sem;
  2147.  
  2148.     struct    ULock *Next;
  2149. };
  2150.  
  2151. struct FidoNet {
  2152.     char from[36];
  2153.     char to  [36];
  2154.     char subject [72];
  2155.     char dateline[20];
  2156.     USHORT time;
  2157.     USHORT destnode;
  2158.     USHORT orignode;
  2159.     USHORT cost;
  2160.     USHORT orignet;
  2161.     USHORT destnet;
  2162.     USHORT destzone;
  2163.     USHORT orignzone;
  2164.     USHORT destpoint;
  2165.     USHORT orignpoint;
  2166.     USHORT replyto;
  2167.     USHORT attribute;
  2168.     USHORT nextrply;
  2169. };
  2170.  
  2171. struct PacketHeader {
  2172.     USHORT    orignode;
  2173.     USHORT    destnode;
  2174.     USHORT    year;
  2175.     USHORT    month;
  2176.     USHORT    day;
  2177.     USHORT    hour;
  2178.     USHORT    minute;
  2179.     USHORT    second;
  2180.     USHORT    baud;
  2181.     USHORT    two_oh;
  2182.     USHORT    orignet;
  2183.     USHORT    destnet;
  2184.     char    fill[34];
  2185. };
  2186.  
  2187. struct PackedMessage {
  2188.     USHORT    two_oh;
  2189.     USHORT    orignode;
  2190.     USHORT    destnode;
  2191.     USHORT    orignet;
  2192.     USHORT    destnet;
  2193.     USHORT    attribute;
  2194.     USHORT    cost;
  2195.     char    date[20];
  2196. };
  2197.  
  2198. struct NodeType {        /* a node that we export-to */
  2199.     char    *buffer;
  2200.     ULONG    buffpos;
  2201.     ULONG    buffsize;
  2202.  
  2203.     USHORT    zone;
  2204.     USHORT    net;
  2205.     USHORT    node;
  2206.     USHORT    point;
  2207.  
  2208.     USHORT    packer;
  2209.     USHORT    format;        /* 4d or 2d */
  2210.     USHORT    type;        /* normal, crash, hold */
  2211.  
  2212.     USHORT    flag;        /* 0-31 ... which subboards? */
  2213.     USHORT    domain;        /* which fido-net domain? */
  2214.  
  2215.     UBYTE    Access;
  2216.     UBYTE    Flags;
  2217.  
  2218.     USHORT    more[4];
  2219.  
  2220.     ULONG    incount;
  2221.     ULONG    outcount;
  2222.  
  2223.     char    Password[12];
  2224. };
  2225.  
  2226. struct RouteType {        /* a netmail routing pattern */
  2227.     USHORT    zone;        /* from ... -1's mean wildcard ... */
  2228.     USHORT    net;
  2229.     USHORT    node;
  2230.     USHORT    point;
  2231.  
  2232.     USHORT    zone2;        /* to */
  2233.     USHORT    net2;
  2234.     USHORT    node2;
  2235.     USHORT    point2;
  2236.  
  2237.     USHORT    domain;        /* which fido-net domain? */
  2238.     USHORT    type;        /* normal, crash, hold */
  2239.  
  2240.     USHORT    more[4];
  2241.  
  2242.     ULONG    outcount;
  2243. };
  2244.  
  2245. struct PacketType {
  2246.     struct    PacketType *next;
  2247.  
  2248.     char    filename[32];
  2249. };
  2250.  
  2251. struct ImportType {
  2252.     struct    ImportType *next;
  2253.     struct    PacketType *file;    /* which packet? */
  2254.  
  2255.     USHORT    zone0, net0, node0, point0;
  2256.  
  2257.     long    seek;
  2258.     long    end;
  2259.     long    seen;        /* index */
  2260.     long    xoff;        /* index */
  2261.  
  2262.     struct    IsDate date;
  2263.  
  2264.     UBYTE    isdupe;
  2265. };
  2266.  
  2267. struct    DupeType {
  2268.     USHORT    zone;
  2269.     USHORT    net;
  2270.     USHORT    node;
  2271.     USHORT    point;
  2272.     ULONG    data;
  2273. };
  2274.  
  2275. struct    EchoType {
  2276.     char    Title[24];
  2277.     ULONG    ExportTo[4];        /* export to which node types */
  2278.  
  2279.     struct    ImportType *first;    /* during toss, list to import */
  2280.     struct    ImportType *last;
  2281.  
  2282.     USHORT    listn;            /* during toss, which local sub? */
  2283.     USHORT    domain;
  2284.  
  2285.     struct    DupeType *duptab;
  2286.     ULONG    incount;
  2287.     ULONG    outcount;
  2288.  
  2289.     USHORT    dupsize;
  2290.  
  2291.     UBYTE    dupdelta;
  2292.     UBYTE    Access;
  2293.     UBYTE    Flags;
  2294.  
  2295.     UBYTE    other[3];
  2296.  
  2297.     char    Info[48];
  2298. };
  2299.  
  2300. struct    BBSItem {
  2301.     long    ID;
  2302.  
  2303.     char    Phone[16];
  2304.     char    Title[26];
  2305.     char    Location[21];
  2306.     char    Baud[6];
  2307.     char    Comments[62];
  2308.     char    Country[4];
  2309.     char    Flags[10];
  2310.  
  2311.     UBYTE    Immortal;
  2312.  
  2313.     struct    IsDate Date;
  2314. };
  2315.